package guoanmaker.provider.business.modelnobind;

import java.util.Date;
import java.util.List;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.OneToOne;
import javax.persistence.Table;
import javax.persistence.Transient;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

import guoanmaker.provider.business.model.ProvideCommodityServiceRange;
import guoanmaker.provider.business.model.OperatorServerClass;
import guoanmaker.provider.helper.common.abstractobj.IdEntity;
import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

@Getter
@Setter
@AllArgsConstructor
@NoArgsConstructor


public class ProvideCommodityMove  {
	private String id;//商品主键
	private String commodityName; //商品名称
	private String businessName;//商户名称
	private String isBargaining; //是否议价 1:议价 2:不可议价
	private Double startingPrice; //议价起始值
	private String measurementUnit;//计量单位
	private String invoiceMail;//发票邮寄 1:货到付款 2:包邮
	private String isTerritoryRestriction;//是否有地域限制 1:有 2:没有
	private List<ProvideCommodityServiceMove> serviceRange;
	private Integer commodityCode;//商品编号
	private Double commodityPrice; //商品现价
	private Double commodityPricePromotion;//商品促销价
	private Date startTime;//商品促销开始时间
	private Date endTime;//商品促销结束时间
	private String commodity_bigimage;//商品大图
	private String description;//图文描述
	private Integer commodityState;//商品状态 1:待审核 2:审核通过 3:审核失败 4:下架 5:冻结
	private Date releaseTime;//发布时间
	private Integer stock;//商品库存
	private Integer populationRestriction;//人数限制
	private Date registrationStartTime;//报名开始时间
	private Date registrationEndTime;//报名结束时间
	private String synopsis;//商品简介
	private Double finalPrice;//最终价格
	private String type;//商品所属大类 1:空间商品 2:其他 3:培训
	private String serverName;//所属类型名称
	private Integer isPromotion;//是否促销
	private Integer clickRate;//点击量
	private String process;//流程
	private String promise;//承诺
	private String introduce;//商品介绍
	private String commodityCase;//案例
	private String auditOpinion;//审核意见
	private String companyCity;//商家注册地
	private String commodity_smallimage;//商品小图
	private Integer salesVolume;//商品销售量
	private String cityName;//城市名称
	private String LicensPhone;//商家联系电话
	private Integer isCollection;//是否收藏 1:收藏 2:未收藏
	private String guarantee; //平台保障须知
	private String reasoncontent; //审批内容  商品表
	private Integer evaluateValue;//商品评价数量
	private Integer isSeckill;//是否秒杀 1:不是 2:是
	private String secckillId;//秒杀规则id
	private  Date nowTime;//系统时间
	private String businessId;//服务商id
	private String collectionId;//收藏id
	private List<PersonalAppraiseMove> personalAppraises;//商品评论

	//空间商品详情
	public ProvideCommodityMove(String commodityName, String businessName, String isBargaining, Double startingPrice,
				String measurementUnit, String invoiceMail, String isTerritoryRestriction, 
				Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
				String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
				Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,String serverName
				,Integer isPromotion,Integer clickRate,String process,String promise,String commodityCase,String auditOpinion,Double finalPrice,String introduce
				,String commodity_smallimage,String LicensPhone,String companyCity,Integer salesVolume) {
			this.commodityName = commodityName;
			this.businessName = businessName;
			this.isBargaining = isBargaining;
			this.startingPrice = startingPrice;
			this.measurementUnit = measurementUnit;
			this.invoiceMail = invoiceMail;
			this.isTerritoryRestriction = isTerritoryRestriction;
			this.commodityPrice = commodityPrice;
			this.commodityPricePromotion = commodityPricePromotion;
			this.startTime = startTime;
			this.endTime = endTime;
			this.commodity_bigimage = commodity_bigimage;
			this.description = description;
			this.commodityState = commodityState;
			this.releaseTime = releaseTime;
			this.stock = stock;
			this.populationRestriction = populationRestriction;
			this.registrationStartTime = registrationStartTime;
			this.registrationEndTime = registrationEndTime;
			this.synopsis = synopsis;
			this.id = id;
			this.type = type;
			this.serverName=serverName;
			this.isPromotion=isPromotion;
			this.clickRate=clickRate;
			this.process=process;
			this.promise=promise;
			this.commodityCase=commodityCase;
			this.auditOpinion=auditOpinion;
			this.finalPrice=finalPrice;
			this.introduce=introduce;
			this.commodity_smallimage=commodity_smallimage;
			this.LicensPhone=LicensPhone;
			this.companyCity=companyCity;
			this.salesVolume=salesVolume;
		}
	
	public ProvideCommodityMove(String commodityName, String businessName){
		this.commodityName = commodityName;
		this.businessName = businessName;
	}
	
	public ProvideCommodityMove(Double finalPrice){
		this.finalPrice = finalPrice;
	}
	
	//服务商后台商品列表
	public ProvideCommodityMove(String id, String commodityName,Double finalPrice,Integer stock,Integer salesVolume,Date releaseTime,
			String auditOpinion,String commodity_smallimage,String serverName,Integer commodityCode, String reasoncontent){
		this.id = id;
		this.commodityName = commodityName;
		this.finalPrice=finalPrice;
		this.stock=stock;
		this.salesVolume=salesVolume;
		this.releaseTime=releaseTime;
		this.auditOpinion=auditOpinion;
		this.commodity_smallimage=commodity_smallimage;
		this.serverName=serverName;
		this.commodityCode=commodityCode;
		this.reasoncontent=reasoncontent;
	}
	
	//地区商品列表用到的构造方法
	public ProvideCommodityMove(String commodityName, String businessName, String isBargaining, Double startingPrice,
			String measurementUnit, String invoiceMail, String isTerritoryRestriction, 
			Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
			String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
			Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,String serverName
			,Integer isPromotion,Integer clickRate,String companyCity,String commodity_smallimage,Integer salesVolume,Double finalPrice,Integer evaluateValue) {
		this.commodityName = commodityName;
		this.businessName = businessName;
		this.isBargaining = isBargaining;
		this.startingPrice = startingPrice;
		this.measurementUnit = measurementUnit;
		this.invoiceMail = invoiceMail;
		this.isTerritoryRestriction = isTerritoryRestriction;
		this.commodityPrice = commodityPrice;
		this.commodityPricePromotion = commodityPricePromotion;
		this.startTime = startTime;
		this.endTime = endTime;
		this.commodity_bigimage = commodity_bigimage;
		this.description = description;
		this.commodityState = commodityState;
		this.releaseTime = releaseTime;
		this.stock = stock;
		this.populationRestriction = populationRestriction;
		this.registrationStartTime = registrationStartTime;
		this.registrationEndTime = registrationEndTime;
		this.synopsis = synopsis;
		this.id = id;
		this.type = type;
		this.serverName=serverName;
		this.isPromotion=isPromotion;
		this.clickRate=clickRate;
		this.companyCity=companyCity;
		this.commodity_smallimage=commodity_smallimage;
		this.salesVolume=salesVolume;
		this.finalPrice=finalPrice;
		this.evaluateValue=evaluateValue;
	}
	
	
	
	
	//商品详情  selectByCommodityCode()
		public ProvideCommodityMove(String commodityName, String businessName, String isBargaining, Double startingPrice,
				String measurementUnit, String invoiceMail, String isTerritoryRestriction, 
				Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
				String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
				Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,String serverName
				,Integer isPromotion,Integer clickRate,String process,String promise,String commodityCase,String auditOpinion,Double finalPrice,String introduce
				,String commodity_smallimage,String LicensPhone,String businessId) {
			this.commodityName = commodityName;
			this.businessName = businessName;
			this.isBargaining = isBargaining;
			this.startingPrice = startingPrice;
			this.measurementUnit = measurementUnit;
			this.invoiceMail = invoiceMail;
			this.isTerritoryRestriction = isTerritoryRestriction;
			this.commodityPrice = commodityPrice;
			this.commodityPricePromotion = commodityPricePromotion;
			this.startTime = startTime;
			this.endTime = endTime;
			this.commodity_bigimage = commodity_bigimage;
			this.description = description;
			this.commodityState = commodityState;
			this.releaseTime = releaseTime;
			this.stock = stock;
			this.populationRestriction = populationRestriction;
			this.registrationStartTime = registrationStartTime;
			this.registrationEndTime = registrationEndTime;
			this.synopsis = synopsis;
			this.id = id;
			this.type = type;
			this.serverName=serverName;
			this.isPromotion=isPromotion;
			this.clickRate=clickRate;
			this.process=process;
			this.promise=promise;
			this.commodityCase=commodityCase;
			this.auditOpinion=auditOpinion;
			this.finalPrice=finalPrice;
			this.introduce=introduce;
			this.commodity_smallimage=commodity_smallimage;
			this.LicensPhone=LicensPhone;
			this.businessId=businessId;
		}
	
	
	
	
	
	
	//商品详情 ProvideCommodityMoveService(selectById方法)
	public ProvideCommodityMove(String commodityName, String businessName, String isBargaining, Double startingPrice,
			String measurementUnit, String invoiceMail, String isTerritoryRestriction, 
			Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
			String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
			Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,String serverName
			,Integer isPromotion,Integer clickRate,String process,String promise,String commodityCase,String auditOpinion,Double finalPrice,String introduce
			,String commodity_smallimage,String LicensPhone,Integer salesVolume,String businessId) {
		this.commodityName = commodityName;
		this.businessName = businessName;
		this.isBargaining = isBargaining;
		this.startingPrice = startingPrice;
		this.measurementUnit = measurementUnit;
		this.invoiceMail = invoiceMail;
		this.isTerritoryRestriction = isTerritoryRestriction;
		this.commodityPrice = commodityPrice;
		this.commodityPricePromotion = commodityPricePromotion;
		this.startTime = startTime;
		this.endTime = endTime;
		this.commodity_bigimage = commodity_bigimage;
		this.description = description;
		this.commodityState = commodityState;
		this.releaseTime = releaseTime;
		this.stock = stock;
		this.populationRestriction = populationRestriction;
		this.registrationStartTime = registrationStartTime;
		this.registrationEndTime = registrationEndTime;
		this.synopsis = synopsis;
		this.id = id;
		this.type = type;
		this.serverName=serverName;
		this.isPromotion=isPromotion;
		this.clickRate=clickRate;
		this.process=process;
		this.promise=promise;
		this.commodityCase=commodityCase;
		this.auditOpinion=auditOpinion;
		this.finalPrice=finalPrice;
		this.introduce=introduce;
		this.commodity_smallimage=commodity_smallimage;
		this.LicensPhone=LicensPhone;
		this.salesVolume=salesVolume;
		this.businessId=businessId;
	}
	public ProvideCommodityMove(String commodityName, String isBargaining, Double startingPrice,
			String invoiceMail, String isTerritoryRestriction, 
			Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
			String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
			Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,
			Integer isPromotion,Integer clickRate,String commodity_smallimage,Integer salesVolume) {
		this.commodityName = commodityName;
		this.isBargaining = isBargaining;
		this.startingPrice = startingPrice;
		this.invoiceMail = invoiceMail;
		this.isTerritoryRestriction = isTerritoryRestriction;
		this.commodityPrice = commodityPrice;
		this.commodityPricePromotion = commodityPricePromotion;
		this.startTime = startTime;
		this.endTime = endTime;
		this.commodity_bigimage = commodity_bigimage;
		this.description = description;
		this.commodityState = commodityState;
		this.releaseTime = releaseTime;
		this.stock = stock;
		this.populationRestriction = populationRestriction;
		this.registrationStartTime = registrationStartTime;
		this.registrationEndTime = registrationEndTime;
		this.synopsis = synopsis;
		this.id = id;
		this.type = type;
		this.isPromotion=isPromotion;
		this.clickRate=clickRate;
		this.commodity_smallimage=commodity_smallimage;
		this.salesVolume=salesVolume;
	}
	
	
	//全国商品用到
	public ProvideCommodityMove(String commodityName, String isBargaining, Double startingPrice,
			String invoiceMail, String isTerritoryRestriction, 
			Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
			String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
			Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,
			Integer isPromotion,Integer clickRate,String commodity_smallimage,Integer salesVolume,Double finalPrice,Integer evaluateValue) {
		this.commodityName = commodityName;
		this.isBargaining = isBargaining;
		this.startingPrice = startingPrice;
		this.invoiceMail = invoiceMail;
		this.isTerritoryRestriction = isTerritoryRestriction;
		this.commodityPrice = commodityPrice;
		this.commodityPricePromotion = commodityPricePromotion;
		this.startTime = startTime;
		this.endTime = endTime;
		this.commodity_bigimage = commodity_bigimage;
		this.description = description;
		this.commodityState = commodityState;
		this.releaseTime = releaseTime;
		this.stock = stock;
		this.populationRestriction = populationRestriction;
		this.registrationStartTime = registrationStartTime;
		this.registrationEndTime = registrationEndTime;
		this.synopsis = synopsis;
		this.id = id;
		this.type = type;
		this.isPromotion=isPromotion;
		this.clickRate=clickRate;
		this.commodity_smallimage=commodity_smallimage;
		this.salesVolume=salesVolume;
		this.finalPrice=finalPrice;
		this.evaluateValue=evaluateValue;
	}
	
	
		//搜索全国商品用到 selectKeyNameCodeSpaceCommodity()
		public ProvideCommodityMove(String commodityName, String isBargaining, Double startingPrice,String measurementUnit,
				String invoiceMail, String isTerritoryRestriction, 
				Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
				String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
				Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,
				Integer isPromotion,Integer clickRate,String commodity_smallimage,Integer salesVolume,Double finalPrice,String companyCity
				,String LicensPhone,String promise,String businessId,String businessName) {
			this.commodityName = commodityName;
			this.isBargaining = isBargaining;
			this.startingPrice = startingPrice;
			this.measurementUnit=measurementUnit;
			this.invoiceMail = invoiceMail;
			this.isTerritoryRestriction = isTerritoryRestriction;
			this.commodityPrice = commodityPrice;
			this.commodityPricePromotion = commodityPricePromotion;
			this.startTime = startTime;
			this.endTime = endTime;
			this.commodity_bigimage = commodity_bigimage;
			this.description = description;
			this.commodityState = commodityState;
			this.releaseTime = releaseTime;
			this.stock = stock;
			this.populationRestriction = populationRestriction;
			this.registrationStartTime = registrationStartTime;
			this.registrationEndTime = registrationEndTime;
			this.synopsis = synopsis;
			this.id = id;
			this.type = type;
			this.isPromotion=isPromotion;
			this.clickRate=clickRate;
			this.commodity_smallimage=commodity_smallimage;
			this.salesVolume=salesVolume;
			this.finalPrice=finalPrice;
			this.companyCity=companyCity;
			this.LicensPhone=LicensPhone;
			this.promise=promise;
			this.businessId=businessId;
			this.businessName = businessName;
		}

		//搜索地区商品列表用到的构造方法 selectKeyNameCodeSpaceCommodity()
		public ProvideCommodityMove(String commodityName, String businessName, String isBargaining, Double startingPrice,
				String measurementUnit, String invoiceMail, String isTerritoryRestriction, 
				Double commodityPrice, Double commodityPricePromotion, Date startTime, Date endTime,
				String commodity_bigimage, String description, Integer commodityState, Date releaseTime, Integer stock,
				Integer populationRestriction, Date registrationStartTime, Date registrationEndTime, String synopsis,String id,String type,String serverName
				,Integer isPromotion,Integer clickRate,String companyCity,String commodity_smallimage,Integer salesVolume,Double finalPrice,String promise
				,String licensPhone,String businessId) {
			this.commodityName = commodityName;
			this.businessName = businessName;
			this.isBargaining = isBargaining;
			this.startingPrice = startingPrice;
			this.measurementUnit = measurementUnit;
			this.invoiceMail = invoiceMail;
			this.isTerritoryRestriction = isTerritoryRestriction;
			this.commodityPrice = commodityPrice;
			this.commodityPricePromotion = commodityPricePromotion;
			this.startTime = startTime;
			this.endTime = endTime;
			this.commodity_bigimage = commodity_bigimage;
			this.description = description;
			this.commodityState = commodityState;
			this.releaseTime = releaseTime;
			this.stock = stock;
			this.populationRestriction = populationRestriction;
			this.registrationStartTime = registrationStartTime;
			this.registrationEndTime = registrationEndTime;
			this.synopsis = synopsis;
			this.id = id;
			this.type = type;
			this.serverName=serverName;
			this.isPromotion=isPromotion;
			this.clickRate=clickRate;
			this.companyCity=companyCity;
			this.commodity_smallimage=commodity_smallimage;
			this.salesVolume=salesVolume;
			this.finalPrice=finalPrice;
			this.promise=promise;
			this.LicensPhone=licensPhone;
			this.businessId=businessId;
		}
}
